home *** CD-ROM | disk | FTP | other *** search
/ Disc to the Future 2 / Disc to the Future Part II Programmer's Reference (Wayzata Technology)(6013)(1992).bin / MAC / THINKC / 1_0-2 / D2R_FOLD / D2R_EXIT.C < prev    next >
C/C++ Source or Header  |  1986-11-06  |  348b  |  23 lines

  1. #include "::MacIncludes:MacTypes.h"
  2.  
  3. /* My standard exit routine */
  4.  
  5. my_exit(which)
  6. int which;
  7. {
  8.     int theitem, vRefNum;
  9.     Str255 filename;
  10.     
  11.     if (which == 1)
  12.         if (!transfer(filename,&vRefNum))
  13.             return(1);
  14.     all_winclose();
  15.     if (which == 1)
  16.     {
  17.         SetVol(0L,vRefNum);    /* this should work with HFS */
  18.         Launch(0,filename);
  19.     }
  20.     else
  21.         ExitToShell();
  22. }
  23.